$OpenBSD: patch-code_qcommon_q_platform_h,v 1.3 2015/05/01 16:51:25 ajacoutot Exp $
--- code/qcommon/q_platform.h.orig	Sat Dec 24 14:29:32 2011
+++ code/qcommon/q_platform.h	Tue Mar  6 22:44:31 2012
@@ -209,7 +209,7 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 
 //=================================================================== BSD ===
 
-#if defined(__FreeBSD__) || defined(__OpenBSD__) || defined(__NetBSD__)
+#if defined(__FreeBSD__) || defined(__NetBSD__)
 
 #include <sys/types.h>
 #include <machine/endian.h>
@@ -220,8 +220,6 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 
 #if defined(__FreeBSD__)
 #define OS_STRING "freebsd"
-#elif defined(__OpenBSD__)
-#define OS_STRING "openbsd"
 #elif defined(__NetBSD__)
 #define OS_STRING "netbsd"
 #endif
@@ -247,6 +245,29 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 
 #endif
 
+// --- OpenBSD
+#if defined(__OpenBSD__)
+
+#include <sys/types.h>
+#include <endian.h>
+
+#ifndef __BSD__
+  #define __BSD__
+#endif
+
+#define OS_STRING "openbsd"
+#define ID_INLINE inline
+#define PATH_SEP '/'
+
+#if BYTE_ORDER == BIG_ENDIAN
+#define Q3_BIG_ENDIAN
+#else
+#define Q3_LITTLE_ENDIAN
+#endif
+
+#define DLL_EXT ".so"
+
+#endif
 //================================================================= SUNOS ===
 
 #ifdef __sun
